﻿package com.petermacko.utils {
	public class MathUtil
	{
		//Convert radians to degrees
		public static function radiansToDegrees(rad:Number):Number {
			return Number((180/Math.PI)*rad);
		}
		
		//Convert degrees to radians
		public static function degreesToRadians(deg:Number):Number {
			return Number((Math.PI/180)*deg);
		}
		
		//Return a random number between the limits
		public static function randRange(min:Number,max:Number):Number {
			return min+((max-min)*Math.random());
		}
	}
}